package com.fqgj.xjd.user.dao.impl;
import com.fqgj.common.base.AbstractBaseMapper;
import com.fqgj.xjd.user.dao.UserAuthFaceRecognitionHistoryDao;
import com.fqgj.xjd.user.entity.UserAuthFaceRecognitionHistoryEntity;
import org.springframework.stereotype.Repository;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
* User: zhangxingyun
* Date: 2017-07-20
* Time: 18:38:52.987
*/

@Repository
public class UserAuthFaceRecognitionHistoryDaoImpl extends AbstractBaseMapper<UserAuthFaceRecognitionHistoryEntity> implements UserAuthFaceRecognitionHistoryDao {

    @Override
    public List<UserAuthFaceRecognitionHistoryEntity> selectUserAuthFaceRecognitionHistoryByUserCodeAndType(String userCode, List<Integer> types) {
        Map params = new HashMap();
        params.put("userCode",userCode);
        params.put("types",types);
        return getSqlSession().selectList(getStatement("selectUserAuthFaceRecognitionHistoryByUserCodeAndType"),params);
    }

    @Override
    public void deleteByIdsAndTypes(List<Long> ids, List<Integer> types) {
        Map params = new HashMap();
        params.put("ids",ids);
        params.put("types",types);
        getSqlSession().delete(getStatement("deleteByIdsAndTypes"),params);
    }
}